//
//  EasyNoteDBManger.h
//  todoApp
//
//  Created by wangyaqing on 15/3/24.
//  Copyright (c) 2015年 ll studio. All rights reserved.
//

#import <Foundation/Foundation.h>

@class FMDatabase;
@class NoteModel;

@interface NoteDBManger : NSObject

+ (instancetype)shareInstance;

- (BOOL)addNote:(NoteModel*)note;

- (void)addNotes:(NSArray*)notes;

- (void)deleteAllNotes;

- (void)deleleNotes:(NSArray*)notes;

- (NoteModel*)queryNoteWithId:(NSString*)noteId;

- (NSMutableArray*)queryAllNotes;

- (NSMutableArray *)queryAllTags;

- (NSMutableArray *)queryAllNotesForUser:(NSString*)userId;

- (NSMutableArray *)queryNotesForTag:(NSString*)tag;

- (BOOL)updateNote:(NoteModel*)note;

- (void)closeDataBase;

@property (nonatomic, strong) FMDatabase *dataBase;

@end



